<!DOCTYPE HTML>
<html>
<head>
	<meta charset="utf-8">
	<title>  
	  
  	通用技术学习 - 
  	
	</title>

  <meta name="HandheldFriendly" content="True">
  <meta name="MobileOptimized" content="320">
  <meta name="viewport" content="width=device-width, initial-scale=1">

	<link href="atom.xml" rel="alternate" title="" type="application/atom+xml">

	<link href="asset/stylesheets/screen.css" media="screen, projection" rel="stylesheet" type="text/css">
	<link href="asset/stylesheets/font-awesome.min.css" media="screen, projection" rel="stylesheet" type="text/css">
	<script src="asset/javascripts/jquery.min.js"></script>
	<script src="asset/highlightjs/highlight.pack.js"></script>
	<link href="asset/highlightjs/styles/solarized_dark.css" media="screen, projection" rel="stylesheet" type="text/css">
<script>hljs.initHighlightingOnLoad();</script>

	<!--[if lt IE 9]><script src="asset/javascripts/html5.js"></script><![endif]-->
	<!-- <link href='http://fonts.googleapis.com/css?family=Nunito:400,300,700' rel='stylesheet' type='text/css'> -->
	<style type="text/css">
/* latin */
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 300;
  src: local('Nunito-Light'), url(asset/font/1TiHc9yag0wq3lDO9cw0voX0hVgzZQUfRDuZrPvH3D8.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000;
}
/* latin */
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 400;
  src: local('Nunito-Regular'), url(asset/font/6TbRXKWJjpj6V2v_WyRbMX-_kf6ByYO6CLYdB4HQE-Y.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000;
}
/* latin */
@font-face {
  font-family: 'Nunito';
  font-style: normal;
  font-weight: 700;
  src: local('Nunito-Bold'), url(asset/font/TttUCfJ272GBgSKaOaD7KoX0hVgzZQUfRDuZrPvH3D8.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000;
}
	</style>
	
	<style type="text/css">
	.container .left-col{ opacity: 1;}
	#pagenavi a{ font-size: 1.3em;}
	#pagenavi .next:before{ top: 3px;}
	#pagenavi .prev:before{ top: 3px;}
	.container .mid-col .mid-col-container #content .archives .title{ font-size: 1.5em;}
	.container .mid-col .mid-col-container #content article{ padding: 15px 0px;}
	#header .subtitle {
		line-height: 1.2em;
		padding-top: 8px;
	}
	article pre{ background: none; border: none; padding: 0;}
	article .entry-content{text-align: left;}
	.share-comment{ padding: 25px 0px; clear: both;}
	hr{ margin: 20px 0px;border: 0; border-top:solid 1px #ddd;}
	</style>
  

</head>


<body>
	<div class="container">
		<div class="left-col">
			<div class="intrude-less">
				<header id="header" class="inner">
				 
					
					<h1><a href="index.html"></a></h1>
					<p class="subtitle"></p>
					<nav id="main-nav">
						<ul class="main">
						
						  <li id=""><a target="_self" href="archives.html">目录</a></li>
						
						  <li id=""><a target="_self" href="15254919622349.html">第一章:简介</a></li>
						
						  <li id=""><a target="_self" href="15254954428209.html">第二章:通用技术的学习</a></li>
						
						  <li id=""><a target="_self" href="15254958459733.html">    2.1节:Git</a></li>
						
						</ul>
					</nav>

					<nav id="sub-nav">
						<div class="social">








<a target="_blank" class="weibo" href="https://weibo.com/u/1746639594/home?wvr=5" title="weibo">Weibo</a>

<a target="_blank" class="github" target="_blank" href="https://github.com/DW-Under-Sunshine" title="GitHub">GitHub</a>
<a target="_blank" class="email" href="mailto:15162709915@163.com" title="Email">Email</a>

								

								<a class="rss" href="atom.xml" title="RSS">RSS</a>
							
						</div>
					</nav>
				</header>				
			</div>
		</div>	
		<div class="mid-col">
			<div class="mid-col-container"> <div id="content" class="inner">
<div itemscope itemtype="http://schema.org/Blog">


	<article class="post" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
		<div class="meta">
			<div class="date">
				<time datetime="2018-05-05T12:50:45+08:00" itemprop="datePublished">2018/5/5</time>
			</div>
			<div class="tags">posted in 
			
			    <a class='category' href='Git.html'>Git</a>&nbsp;
			 
			</div>
		</div>
		<h1 class="title" itemprop="name"><a href="15254958459733.html" itemprop="url">
		Git</a></h1>
		<div class="entry-content" itemprop="articleBody">
			
			<ul>
<li><a href="15254942572494.html">Git的作用</a></li>
<li><a href="15254942731489.html">Git的掌握</a></li>
<li><a href="15254942889665.html">Git的应用</a></li>
</ul>


			
			
		</div>

	</article>
 
	<article class="post" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
		<div class="meta">
			<div class="date">
				<time datetime="2018-05-05T12:44:02+08:00" itemprop="datePublished">2018/5/5</time>
			</div>
			<div class="tags">posted in 
			
			    <a class='category' href='%E9%80%9A%E7%94%A8%E6%8A%80%E6%9C%AF%E5%AD%A6%E4%B9%A0.html'>通用技术学习</a>&nbsp;
			 
			</div>
		</div>
		<h1 class="title" itemprop="name"><a href="15254954428209.html" itemprop="url">
		本章内容</a></h1>
		<div class="entry-content" itemprop="articleBody">
			
			<p>这一章节主要就是为了教授屏幕前的你一些我觉得非常有用的工具</p>

<blockquote>
<p>Git</p>
</blockquote>

<p><a href="15254958459733.html">我觉得所有程序员必须得用的,非常方便的,神一样的工具</a></p>

<blockquote>
<p>百度/谷歌</p>
</blockquote>

<p>你知道羊驼为啥会淹死么？</p>

<blockquote>
<p>MarkDown</p>
</blockquote>

<p>想不想写出我这样<del>装逼</del>美观的文档,用他就是了</p>


			
			
		</div>

	</article>
 
	<article class="post" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
		<div class="meta">
			<div class="date">
				<time datetime="2018-05-05T12:24:48+08:00" itemprop="datePublished">2018/5/5</time>
			</div>
			<div class="tags">posted in 
			
			    <a class='category' href='Git.html'>Git</a>&nbsp;
			 
			</div>
		</div>
		<h1 class="title" itemprop="name"><a href="15254942889665.html" itemprop="url">
		Git的应用</a></h1>
		<div class="entry-content" itemprop="articleBody">
			
			<blockquote>
<p>git社区</p>

<blockquote>
<p>社区存在的原因</p>
</blockquote>
</blockquote>

<ul>
<li>你不可能总是把git放在本地,这样还是不能避免万一电脑坏了的问题</li>
<li>我写的代码想<del>装逼</del>让别人也能看到,也能使用</li>
</ul>

<blockquote>
<blockquote>
<p>比较火的社区</p>
</blockquote>
</blockquote>

<ul>
<li>最火,没有之一的肯定是基特哈勃(<a href="https://www.github.com">Github</a>)</li>
<li>因为国内外网络原因,导致你如果使用Github作为你的Git仓库的时候,会慢的头疼,所以推荐国内最大的Git仓库-<a href="http://www.gitee.com">Gitee</a></li>
</ul>

<hr/>

<blockquote>
<p>项目中的使用</p>
</blockquote>

<p><code>前提:假设我们有一个项目A,下面是使用Git环境来管理开发的其中一条方式(命令基于Linux|mac系统)</code></p>

<ul>
<li>本地创建工程,叫project_Test,位置在path</li>
<li>在gitee上创建一个工程project_Test_remote(名字无所谓),复制这个工程的http地址假设为remote_url</li>
</ul>

<pre><code>cd path(本地项目地址)
//进入项目目录

git clone remote_url(云端项目地址)
// 拉取云端项目

cd project_Test_remote(云端项目地址)
//进入云端项目地址

cp -r . ../
//复制git配置到本地项目地址

cd path(本地项目地址)
//进入项目目录

/*接下来你就可以操作git了*/

git add -A
//将目录下所有文件加入仓库

git commit -m &quot;first commit(这就是个注释,解释我这次提交的内容)&quot;
//commit 一个版本

git push 
//上传到云端

</code></pre>

<p><code>如果看到这里还没看懂,你TMD倒是动手敲啊</code></p>


			
			
		</div>

	</article>
 
	<article class="post" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
		<div class="meta">
			<div class="date">
				<time datetime="2018-05-05T12:24:33+08:00" itemprop="datePublished">2018/5/5</time>
			</div>
			<div class="tags">posted in 
			
			    <a class='category' href='Git.html'>Git</a>&nbsp;
			 
			</div>
		</div>
		<h1 class="title" itemprop="name"><a href="15254942731489.html" itemprop="url">
		Git的掌握</a></h1>
		<div class="entry-content" itemprop="articleBody">
			
			<blockquote>
<p>Git详细教程</p>
</blockquote>

<ul>
<li><a href="https://git-scm.com/book/zh/v2">官网文档</a></li>
</ul>

<p><code>友情提醒:官网文档只需要看1,2,3。你要是脑袋转不过弯你可以继续看下去</code></p>

<ul>
<li><a href="https://services.github.com/on-demand/downloads/github-git-cheat-sheet.pdf">常用语句</a></li>
</ul>

<blockquote>
<p>王师傅简易教程</p>
</blockquote>

<p><code>前提是你先看完官网文档的1,2,3节</code></p>

<ul>
<li>克隆:</li>
</ul>

<pre><code>git clone 项目地址

这句话的作用就是在你看到别人比较好的代码或者拉自己的项目到本地时使用
</code></pre>

<ul>
<li>添加文件:</li>
</ul>

<pre><code>git add 文件名

这句话的作用就是将你刚创建的文件放到Git的版本树中去,如果需要将所有文件都加入,你就在上面这句话后面加上 -A
</code></pre>

<ul>
<li>提交代码:</li>
</ul>

<pre><code>git commit -m &quot;你对这次提交所需要写的注释&quot;

代码写完了总需要提交吧,需要注意的是,你现在提交的代码只是保存在本地
</code></pre>

<ul>
<li>将本地的提交提交到云端</li>
</ul>

<pre><code>git push
</code></pre>

<ul>
<li>将云端的修改拉到本地</li>
</ul>

<pre><code>git pull
</code></pre>

<p><code>以上几行覆盖了你使用Git的80%以上的操作</code></p>

<p><a href="15254942889665.html">&gt; 点击前往-Git的应用</a></p>


			
			
		</div>

	</article>
 
	<article class="post" itemprop="blogPost" itemscope itemtype="http://schema.org/BlogPosting">
		<div class="meta">
			<div class="date">
				<time datetime="2018-05-05T12:24:17+08:00" itemprop="datePublished">2018/5/5</time>
			</div>
			<div class="tags">posted in 
			
			    <a class='category' href='Git.html'>Git</a>&nbsp;
			 
			</div>
		</div>
		<h1 class="title" itemprop="name"><a href="15254942572494.html" itemprop="url">
		Git的作用</a></h1>
		<div class="entry-content" itemprop="articleBody">
			
			<p>Git的存在主要是解决如下问题:</p>

<ul>
<li>你在你的电脑上辛辛苦苦码了很久的一个项目,突然电脑坏了或者你换了个新电脑,或者你不小心把工程删除了,握了个大草</li>
<li>很多的项目分为几个模块,多人开发,一旦你写了一个公用类,想别人可以用,怎么办？U盘拷贝？</li>
<li>项目部署的时候,你个项目打包可能几十个M,国内服务器还好说,但是国外服务器因为某些原因,上传速度贼鸡儿慢,怎么办？</li>
<li>如果说你完成了某一大功能的编写,继续某些小功能,写到一半发现这个小功能不要做,想回到上个大功能写完的状态,怎么办？一个一个删除?</li>
</ul>

<p><code>这些问题就交给Git解决吧,在Git面前,这都不是问题</code></p>

<p><a href="15254942731489.html">&gt; 点击前往-Git的掌握</a></p>


			
			
		</div>

	</article>
  

</div>
<nav id="pagenavi">
	 
	
	<div class="center"><a href="archives.html">Blog Archives</a></div>

</nav>

</div>



        </div>
			<footer id="footer" class="inner">Copyright &copy; 2014
Powered by <a target="_blank" href="http://www.mweb.im">MWeb</a> &nbsp;&nbsp; 
Theme by <a href="http://shashankmehta.in/archive/2012/greyshade.html">Shashank Mehta</a>
      </footer>
		</div>
	</div>

  
    



</body>
</html>